[KYUUBI #7495][KUBERNETES] Avoid overlong pod log directory names#7496
Closed
ruanwenjun wants to merge 1 commit into
Closed
[KYUUBI #7495][KUBERNETES] Avoid overlong pod log directory names#7496ruanwenjun wants to merge 1 commit into
ruanwenjun wants to merge 1 commit into
Conversation
Member
|
this makes sense, and maybe we want a config to always rewrite the name for safety (this can be implemented in a dedicated PR) |
Member
Author
|
@pan3793 Yes, Kyuubi provides the following configurations, and they work as expected: When enabled, Kyuubi rewrites all pod names and therefore avoids the problem. However, when these options are disabled, there is a bug in the current pod name length validation logic that can result in invalid pod names being accepted. |
Member
|
oh, we already have this feature. |
pan3793
approved these changes
Jun 4, 2026
Member
Author
|
Is this PR ready to merge? cc@pan3793 |
pan3793
pushed a commit
that referenced
this pull request
Jun 10, 2026
### Why are the changes needed? Kyuubi currently limits generated Spark driver pod names and executor pod name prefixes only against the Kubernetes pod name limit. However, kubelet creates pod log directories with the `namespace_podName_podUID` format. When the generated pod name is close to the Kubernetes pod name limit, the log directory name can exceed the Linux path component limit and kubelet fails to create it. This patch makes the generated driver pod name and executor pod name prefix reserve the kubelet pod log directory budget. Closes #7495. ### How was this patch tested? - `env PATH="/tmp/kyuubi-black-22.3.0/bin:$PATH" dev/reformat` - `git diff --check HEAD~1..HEAD` - `build/mvn test -pl kyuubi-server -am -Dtest=none -DwildcardSuites=org.apache.kyuubi.util.KubernetesPodNameSuite` - `build/mvn test -pl externals/kyuubi-spark-sql-engine -am -Dtest=none -DwildcardSuites=org.apache.kyuubi.engine.spark.SparkSQLEngineSuite` ### Was this patch authored or co-authored using generative AI tooling? Assisted-by: OpenAI Codex (GPT-5) Closes #7496 from ruanwenjun/kyuubi-7495-pod-log-name. Closes #7495 aa5bc55 [ruanwenjun] [KYUUBI #7495] Avoid overlong Kubernetes pod log names Authored-by: ruanwenjun <wenjun@apache.org> Signed-off-by: Cheng Pan <chengpan@apache.org> (cherry picked from commit 6f6e0eb) Signed-off-by: Cheng Pan <chengpan@apache.org>
pan3793
pushed a commit
that referenced
this pull request
Jun 10, 2026
### Why are the changes needed? Kyuubi currently limits generated Spark driver pod names and executor pod name prefixes only against the Kubernetes pod name limit. However, kubelet creates pod log directories with the `namespace_podName_podUID` format. When the generated pod name is close to the Kubernetes pod name limit, the log directory name can exceed the Linux path component limit and kubelet fails to create it. This patch makes the generated driver pod name and executor pod name prefix reserve the kubelet pod log directory budget. Closes #7495. ### How was this patch tested? - `env PATH="/tmp/kyuubi-black-22.3.0/bin:$PATH" dev/reformat` - `git diff --check HEAD~1..HEAD` - `build/mvn test -pl kyuubi-server -am -Dtest=none -DwildcardSuites=org.apache.kyuubi.util.KubernetesPodNameSuite` - `build/mvn test -pl externals/kyuubi-spark-sql-engine -am -Dtest=none -DwildcardSuites=org.apache.kyuubi.engine.spark.SparkSQLEngineSuite` ### Was this patch authored or co-authored using generative AI tooling? Assisted-by: OpenAI Codex (GPT-5) Closes #7496 from ruanwenjun/kyuubi-7495-pod-log-name. Closes #7495 aa5bc55 [ruanwenjun] [KYUUBI #7495] Avoid overlong Kubernetes pod log names Authored-by: ruanwenjun <wenjun@apache.org> Signed-off-by: Cheng Pan <chengpan@apache.org> (cherry picked from commit 6f6e0eb) Signed-off-by: Cheng Pan <chengpan@apache.org>
Member
|
thanks, merged for 1.12.0/1.11.2/1.10.4 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why are the changes needed?
Kyuubi currently limits generated Spark driver pod names and executor pod name prefixes only against the Kubernetes pod name limit.
However, kubelet creates pod log directories with the
namespace_podName_podUIDformat. When the generated pod name is close to the Kubernetes pod name limit, the log directory name can exceed the Linux path component limit and kubelet fails to create it.This patch makes the generated driver pod name and executor pod name prefix reserve the kubelet pod log directory budget. Closes #7495.
How was this patch tested?
env PATH="/tmp/kyuubi-black-22.3.0/bin:$PATH" dev/reformatgit diff --check HEAD~1..HEADbuild/mvn test -pl kyuubi-server -am -Dtest=none -DwildcardSuites=org.apache.kyuubi.util.KubernetesPodNameSuitebuild/mvn test -pl externals/kyuubi-spark-sql-engine -am -Dtest=none -DwildcardSuites=org.apache.kyuubi.engine.spark.SparkSQLEngineSuiteWas this patch authored or co-authored using generative AI tooling?
Assisted-by: OpenAI Codex (GPT-5)